<!DOCTYPE html>
<html class="x-admin-sm">

<head>
	<meta charset="UTF-8">
	<title>{$list.webtitle}</title>
	<meta name="renderer" content="webkit">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width,user-scalable=yes, minimum-scale=0.4, initial-scale=0.8,target-densitydpi=low-dpi" />
	{load href="__XADMIN__/css/font.css" /}
	{load href="__XADMIN__/css/xadmin.css" /}
	{load href="__XADMIN__/js/jquery.min.js" /}
	{load href="__STATIC__/mayi/css/studentSearch.css" /}
	{load href="__XADMIN__/lib/layui/layui.js" /}
	{load href="__XADMIN__/js/xadmin.js" /}
	{load href="__XADMIN__/js/cookie.js" /}
	{load href="__XADMIN__/js/md5.min.js" /}
	<title>{$list.webtitle}</title>
</head>

<body>
	<div class="myrow">
		<div class="layui-row layui-col-md12">
			<div class="layui-col-xs12 layui-col-sm6 layui-col-md4 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						各学科总分
					</div>
					<div class="mydivtubiao">
						<div id="yibiao" style="width:100%; height:100%;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs12 layui-col-sm12 layui-col-md8 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						各学科得分
					</div>
					<div class="mydivtubiao" style="width:300; height:300;">
						<table id="tabledemo" lay-filter="mytable" lay-size="sm"></table>
					</div>
				</div>
			</div>
			<div class="layui-col-xs12 layui-col-sm6 layui-col-md4 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						各学科得分率
					</div>
					<div class="mydivtubiao">
						<div id="myDefenlv" style="width:100%; height:100%;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs12 layui-col-sm6 layui-col-md4 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						各学科成绩与平均分对比
					</div>
					<div class="mydivtubiao">
						<div id="leida" style="width:100%; height:100%;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs12 layui-col-sm6 layui-col-md4 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						各学科成绩位置
					</div>
					<div class="mydivtubiao">
						<div id="myQweizhi" style="width:100%; height:100%;"></div>
					</div>
				</div>
			</div>
			<div class="layui-col-xs12 layui-col-sm12 layui-col-md12 mydivtop">
				<div class="mydivneirong">
					<div class="mydivtitle">
						成绩报告
					</div>
					<div class="baogao" id="baogao"></div>
				</div>
			</div>
		</div>
	</div>
</body>
<script type="text/javascript">
//config的设置是全局的
layui.config({
	base: "__XADMIN__/js/" //假设这是你存放拓展模块的根目录
});

layui.use(['element','table','myEchart','form'], function() {
	var element = layui.element,
		table = layui.table,
		echart = layui.myEchart,
		form = layui.form;

	// 设置表格初始变量
	defenOptions = {
		elem: '#tabledemo',
		toolbar: '#toolbarDemo',
		url: "/tools/onestudentchengji/xkcj",
		method: "POST", //数据接口
		page: false, //开启分页
		loading: true,
		autoSort: true,
		id: 'mytable',
		defaultToolbar: [],
		limits: [10, 25, 50, 75, 100],
		limit: 10,
		toolbar: false,
	};

	// 设置列
	defenOptions.cols = [
		[ //表头
			{ field: 'subject_name', title: '学科', sort: true },
			{ field: 'defen', title: '得分', sort: true },
			{ field: 'max', title: '最高分', sort: true },
			{ field: 'min', title: '最低分', sort: true },
		]
	];

	// 获取筛选条件并加载表格
	defenOptions.where = {
		kaohao_id: "{$list.id}"
	};

	userTable = table.render(defenOptions); //获取数据并渲染

	loadTubiao();

	function loadTubiao() {
		var val = {
			kaohao_id: "{$list.id}"
		};

		echart.yibiao('/tools/onestudentchengji/yibiao', val, '');
		echart.leida('/tools/onestudentchengji/leida', val, '');
		echart.tiaoxing('myDefenlv', '/tools/onestudentchengji/xkdfl', val, '');
		echart.tiaoxing('myQweizhi', '/tools/onestudentchengji/xkwz', val, '');
		echart.baogao(val.kaohao_id);
	}

});

</script>

</html>
